package com.cyou.dream.define;

import lombok.Getter;
import org.gamedo.common.IContainerKey;

/**
 * 定义规则参数，需要与yml中的ruleParam保持统一
 */
@Getter
public enum ERuleParam implements IContainerKey {

    // 风控系统内部使用
    WINDOW_SECONDS("windowSeconds", Integer.class),

    THRESHOLD("threshold", Integer.class),

    ;

    private final String key;

    public final Class<?> clazz;


    ERuleParam(String key, Class<?> clazz) {
        this.key = key;
        this.clazz = clazz;
    }


    @Override
    public Class<?> getType() {
        return this.clazz;
    }

    @Override
    public String get() {
        return this.key;
    }
}
